package com.rfchina.okr.xianren.task;

import java.util.List;

import com.rfchina.okr.xianren.model.TaskInfo;

public class TaskAudit implements Runnable {

	@Override
	public void run() {

		String sql = "select * from task_info where status=1 order by id limit 10";
		List<TaskInfo> list = TaskInfo.dao.find(sql);
		for (TaskInfo info : list) {
			TaskInfo t = new TaskInfo();
			t.setId(info.getId());
			// 1 创建 2 正常 3进行中 10 任务完成,
			t.setStatus(2);
			// 1审批中,2审批通过,3审批不通过
			t.setAuditStatus(2);
			// 1 初始化,2找人中,3找满
			t.setFindStatus(2);
			String auditComment = "自动审批通过!";
			t.setAuditComment(auditComment);
			t.update();
			
			// 自动派单
			
			   
			
		}


	}

}
